import axios from '@/utils/axios';

// 获取购物车列表
export function getAddressList(params) {
    return axios({
        url:'/userAddress/page',
        method: 'get',
        params
    });
}
export function getAllAddress() {
    return axios({
        url:'/userAddress/all',
        method: 'get'
    });
}
// 添加地址
export function addUserAddress(data) {
    return axios({
        url:'/userAddress/add',
        method: 'post',
        data
    });
}

// 修改地址
export function updateUserAddress(params,data) {
    return axios({
        url:'/userAddress/update/'+params,
        method: 'put',
        data
    });
}
// 删除地址
export function deleteUserAddress(params) {
    return axios({
        url:'/userAddress/delete/'+params,
        method: 'delete'
    });
}

